package org.tgcloud.group.web.controller.manager;

import io.swagger.annotations.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.tgcloud.group.core.APPResultMessage;
import org.tgcloud.group.core.session.Session;
import org.tgcloud.group.service.manager.ProjectHistoryService;

/**
 * @author: zhy
 * @create: 2023-10-13 17:14
 * @description: 项目记录
 */
@Api(tags = "项目记录管理相关接口")
@RestController
@RequestMapping("/manager/pc/user")
@EnableAutoConfiguration
public class ProjectHistoryManageController extends ManageAPPBaseController{


    @Autowired
    private ProjectHistoryService projectHistoryService;


    @ApiOperation(value = "导入excel")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "token", value = "token", required = true, dataType = "string")
    })
    @ResponseBody
    @RequestMapping(value = "/importExcelProjectHistory", method = RequestMethod.POST)
    public APPResultMessage doImportExcelProjectHistory(@RequestPart("file") MultipartFile file,
                                          @ModelAttribute("session") Session session){
        return projectHistoryService.doImportExcelProjectHistory(file);
    }


}
